package part2;

import java.util.Comparator;

public interface OrderedList<E> extends List<E>,
		Comparable<OrderedList<? extends E>> {
		
	/* inserts the specified element in this list, 
	 * respecting the natural order defined on the elements */
	boolean add(E e);
	
	/* inserts all of the elements returned by the 
	 * specified iterator into this list, respecting 
	 * the natural order defined on the elements */
	boolean addAll(Iterable<E> o1);
	
	/* returns the greatest element contained in this list */
	E max();
	
	/* inserts all the elements of the specified list into this list, respecting the
	natural ordering defined on the elements */
	void merge(OrderedList<? extends E> list);
	
	Comparator<? super E> getComparator();

}
